package edu.sctu.practice.class01.liangyuxiang.work.text1;

import java.util.Scanner;

/**
 * Created by 梁玉翔 on 2015/10/15.
 */
public class Aclass {

    int v = 100;

    public void guess() {
        System.out.println("请输入一个整数");
        Scanner scanner = new Scanner(System.in);
        int a = scanner.nextInt();
        if (a != v) {
            if (a < v) {
                System.out.println("小了");
            }
            if (a > v) {
                System.out.println("大了");
            }
        } else {
            System.out.println("猜对了");
        }
    }
}
